package com.xhui.thread;

/**
 * Author XHui
 * Date 2023/1/20 9:35
 * Version 1.0
 */
public class MyThread extends Thread {

    @Override
    public void run() {
        for (int i = 0; i < 1000; i++) {
            System.out.println(Thread.currentThread().getName() + " ==> " + i);
        }
    }

    public static void main(String[] args) {
        // 我的线程的run方法
        MyThread thread = new MyThread();
        thread.start();

        for (int i = 0; i < 1000; i++) {
            System.out.println(Thread.currentThread().getName() + " ==> " + i);
        }
    }

}
